Skip to content

Rewrite ragged sublibrary using complete v3 VectorOfArray code#559

Merged
ChrisRackauckas merged 4 commits intoSciML:masterfrom
ChrisRackauckas-Claude:cr/ragged-v3-complete
Apr 1, 2026
Merged

Rewrite ragged sublibrary using complete v3 VectorOfArray code#559
ChrisRackauckas merged 4 commits intoSciML:masterfrom
ChrisRackauckas-Claude:cr/ragged-v3-complete

Conversation

@ChrisRackauckas-Claude
Copy link
Copy Markdown
Contributor

Summary

Replaces the partial reimplementation of RecursiveArrayToolsRaggedArrays with the complete v3 vector_of_array.jl code, mechanically transformed:

v3 Ragged sublibrary
VectorOfArray RaggedVectorOfArray
DiffEqArray RaggedDiffEqArray
AbstractVectorOfArray AbstractRaggedVectorOfArray
AbstractDiffEqArray AbstractRaggedDiffEqArray

What this fixes

The previous ragged sublibrary was a partial reimplementation that missed many v3 behaviors. This is now the exact v3 code with renamed types, preserving:

  • A[i] returns the i-th inner array (not scalar)
  • A[:, i] returns inner array without zero-padding
  • RaggedEnd for per-column end resolution (r[end, i] gives last element of column i)
  • Iteration over inner arrays
  • Full broadcasting, copy, zero, similar, fill!, push!, append!, reverse, etc.
  • Complete _getindex dispatch with symbolic type checking

Tests

The complete v3 test suite (basic_indexing.jl + interface_tests.jl) with same type renames, plus new tests for interp/dense fields, conversion between ragged/non-ragged types, and SymbolicIndexingInterface.

430 tests pass.

Addresses feedback from @JoshuaLampert in #547.

🤖 Generated with Claude Code

ChrisRackauckas and others added 4 commits April 1, 2026 10:11
Replace the partial reimplementation with the complete v3 vector_of_array.jl
code, mechanically transformed (VectorOfArray → RaggedVectorOfArray, etc.).

This preserves ALL v3 behavior exactly:
- A[i] returns the i-th inner array
- A[:, i] returns inner array without zero-padding
- RaggedEnd for per-column `end` resolution
- Iteration over inner arrays
- Full broadcasting, copy, zero, similar, fill!, push!, etc.

Tests are the complete v3 test suite (basic_indexing + interface_tests)
with same type renames, plus tests for interp/dense, conversion, and SII.

430 tests pass.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Run each sublibrary's test suite as a separate CI group:
- RaggedArrays: RecursiveArrayToolsRaggedArrays (430 tests)
- ArrayPartitionAnyAll: optimized any/all (30 tests)
- ShorthandConstructors: VA[...]/AP[...] syntax (7 tests)

Each group activates the sublibrary's own Project.toml environment,
dev's the parent package, and runs Pkg.test().

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Julia 1.10 has 1 extra allocation in the broadcast path compared to
1.12+. Use <= 1 instead of == 0.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@ChrisRackauckas ChrisRackauckas merged commit 0d6265a into SciML:master Apr 1, 2026
33 of 37 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants